﻿using System;
using System.CodeDom.Compiler;
using System.Diagnostics;
using Google.Protobuf;
using Google.Protobuf.Reflection;

namespace EggLink.DanhengServer.Proto
{
	// Token: 0x020001A9 RID: 425
	[DebuggerDisplay("{ToString(),nq}")]
	public sealed class ChallengeAvatarInfo : IMessage<ChallengeAvatarInfo>, IMessage, IEquatable<ChallengeAvatarInfo>, IDeepCloneable<ChallengeAvatarInfo>, IBufferMessage
	{
		// Token: 0x17000593 RID: 1427
		// (get) Token: 0x06001321 RID: 4897 RVA: 0x00036A97 File Offset: 0x00034C97
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public static MessageParser<ChallengeAvatarInfo> Parser
		{
			get
			{
				return ChallengeAvatarInfo._parser;
			}
		}

		// Token: 0x17000594 RID: 1428
		// (get) Token: 0x06001322 RID: 4898 RVA: 0x00036A9E File Offset: 0x00034C9E
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public static MessageDescriptor Descriptor
		{
			get
			{
				return ChallengeAvatarInfoReflection.Descriptor.MessageTypes[0];
			}
		}

		// Token: 0x17000595 RID: 1429
		// (get) Token: 0x06001323 RID: 4899 RVA: 0x00036AB0 File Offset: 0x00034CB0
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		MessageDescriptor IMessage.Descriptor
		{
			get
			{
				return ChallengeAvatarInfo.Descriptor;
			}
		}

		// Token: 0x06001324 RID: 4900 RVA: 0x00036AB7 File Offset: 0x00034CB7
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public ChallengeAvatarInfo()
		{
		}

		// Token: 0x06001325 RID: 4901 RVA: 0x00036AC0 File Offset: 0x00034CC0
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public ChallengeAvatarInfo(ChallengeAvatarInfo other) : this()
		{
			this.id_ = other.id_;
			this.index_ = other.index_;
			this.level_ = other.level_;
			this.avatarType_ = other.avatarType_;
			this._unknownFields = UnknownFieldSet.Clone(other._unknownFields);
		}

		// Token: 0x06001326 RID: 4902 RVA: 0x00036B14 File Offset: 0x00034D14
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public ChallengeAvatarInfo Clone()
		{
			return new ChallengeAvatarInfo(this);
		}

		// Token: 0x17000596 RID: 1430
		// (get) Token: 0x06001327 RID: 4903 RVA: 0x00036B1C File Offset: 0x00034D1C
		// (set) Token: 0x06001328 RID: 4904 RVA: 0x00036B24 File Offset: 0x00034D24
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public uint Id
		{
			get
			{
				return this.id_;
			}
			set
			{
				this.id_ = value;
			}
		}

		// Token: 0x17000597 RID: 1431
		// (get) Token: 0x06001329 RID: 4905 RVA: 0x00036B2D File Offset: 0x00034D2D
		// (set) Token: 0x0600132A RID: 4906 RVA: 0x00036B35 File Offset: 0x00034D35
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public uint Index
		{
			get
			{
				return this.index_;
			}
			set
			{
				this.index_ = value;
			}
		}

		// Token: 0x17000598 RID: 1432
		// (get) Token: 0x0600132B RID: 4907 RVA: 0x00036B3E File Offset: 0x00034D3E
		// (set) Token: 0x0600132C RID: 4908 RVA: 0x00036B46 File Offset: 0x00034D46
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public uint Level
		{
			get
			{
				return this.level_;
			}
			set
			{
				this.level_ = value;
			}
		}

		// Token: 0x17000599 RID: 1433
		// (get) Token: 0x0600132D RID: 4909 RVA: 0x00036B4F File Offset: 0x00034D4F
		// (set) Token: 0x0600132E RID: 4910 RVA: 0x00036B57 File Offset: 0x00034D57
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public AvatarType AvatarType
		{
			get
			{
				return this.avatarType_;
			}
			set
			{
				this.avatarType_ = value;
			}
		}

		// Token: 0x0600132F RID: 4911 RVA: 0x00036B60 File Offset: 0x00034D60
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override bool Equals(object other)
		{
			return this.Equals(other as ChallengeAvatarInfo);
		}

		// Token: 0x06001330 RID: 4912 RVA: 0x00036B70 File Offset: 0x00034D70
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public bool Equals(ChallengeAvatarInfo other)
		{
			return other != null && (other == this || (this.Id == other.Id && this.Index == other.Index && this.Level == other.Level && this.AvatarType == other.AvatarType && object.Equals(this._unknownFields, other._unknownFields)));
		}

		// Token: 0x06001331 RID: 4913 RVA: 0x00036BDC File Offset: 0x00034DDC
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override int GetHashCode()
		{
			int num = 1;
			if (this.Id != 0U)
			{
				num ^= this.Id.GetHashCode();
			}
			if (this.Index != 0U)
			{
				num ^= this.Index.GetHashCode();
			}
			if (this.Level != 0U)
			{
				num ^= this.Level.GetHashCode();
			}
			if (this.AvatarType != AvatarType.None)
			{
				num ^= this.AvatarType.GetHashCode();
			}
			if (this._unknownFields != null)
			{
				num ^= this._unknownFields.GetHashCode();
			}
			return num;
		}

		// Token: 0x06001332 RID: 4914 RVA: 0x00036C6C File Offset: 0x00034E6C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override string ToString()
		{
			return JsonFormatter.ToDiagnosticString(this);
		}

		// Token: 0x06001333 RID: 4915 RVA: 0x00036C74 File Offset: 0x00034E74
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void WriteTo(CodedOutputStream output)
		{
			output.WriteRawMessage(this);
		}

		// Token: 0x06001334 RID: 4916 RVA: 0x00036C80 File Offset: 0x00034E80
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		void IBufferMessage.InternalWriteTo(ref WriteContext output)
		{
			if (this.AvatarType != AvatarType.None)
			{
				output.WriteRawTag(8);
				output.WriteEnum((int)this.AvatarType);
			}
			if (this.Level != 0U)
			{
				output.WriteRawTag(32);
				output.WriteUInt32(this.Level);
			}
			if (this.Index != 0U)
			{
				output.WriteRawTag(112);
				output.WriteUInt32(this.Index);
			}
			if (this.Id != 0U)
			{
				output.WriteRawTag(120);
				output.WriteUInt32(this.Id);
			}
			if (this._unknownFields != null)
			{
				this._unknownFields.WriteTo(ref output);
			}
		}

		// Token: 0x06001335 RID: 4917 RVA: 0x00036D10 File Offset: 0x00034F10
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public int CalculateSize()
		{
			int num = 0;
			if (this.Id != 0U)
			{
				num += 1 + CodedOutputStream.ComputeUInt32Size(this.Id);
			}
			if (this.Index != 0U)
			{
				num += 1 + CodedOutputStream.ComputeUInt32Size(this.Index);
			}
			if (this.Level != 0U)
			{
				num += 1 + CodedOutputStream.ComputeUInt32Size(this.Level);
			}
			if (this.AvatarType != AvatarType.None)
			{
				num += 1 + CodedOutputStream.ComputeEnumSize((int)this.AvatarType);
			}
			if (this._unknownFields != null)
			{
				num += this._unknownFields.CalculateSize();
			}
			return num;
		}

		// Token: 0x06001336 RID: 4918 RVA: 0x00036D98 File Offset: 0x00034F98
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void MergeFrom(ChallengeAvatarInfo other)
		{
			if (other == null)
			{
				return;
			}
			if (other.Id != 0U)
			{
				this.Id = other.Id;
			}
			if (other.Index != 0U)
			{
				this.Index = other.Index;
			}
			if (other.Level != 0U)
			{
				this.Level = other.Level;
			}
			if (other.AvatarType != AvatarType.None)
			{
				this.AvatarType = other.AvatarType;
			}
			this._unknownFields = UnknownFieldSet.MergeFrom(this._unknownFields, other._unknownFields);
		}

		// Token: 0x06001337 RID: 4919 RVA: 0x00036E10 File Offset: 0x00035010
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void MergeFrom(CodedInputStream input)
		{
			input.ReadRawMessage(this);
		}

		// Token: 0x06001338 RID: 4920 RVA: 0x00036E1C File Offset: 0x0003501C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		void IBufferMessage.InternalMergeFrom(ref ParseContext input)
		{
			uint num;
			while ((num = input.ReadTag()) != 0U)
			{
				if (num <= 32U)
				{
					if (num == 8U)
					{
						this.AvatarType = (AvatarType)input.ReadEnum();
						continue;
					}
					if (num == 32U)
					{
						this.Level = input.ReadUInt32();
						continue;
					}
				}
				else
				{
					if (num == 112U)
					{
						this.Index = input.ReadUInt32();
						continue;
					}
					if (num == 120U)
					{
						this.Id = input.ReadUInt32();
						continue;
					}
				}
				this._unknownFields = UnknownFieldSet.MergeFieldFrom(this._unknownFields, ref input);
			}
		}

		// Token: 0x040007E2 RID: 2018
		private static readonly MessageParser<ChallengeAvatarInfo> _parser = new MessageParser<ChallengeAvatarInfo>(() => new ChallengeAvatarInfo());

		// Token: 0x040007E3 RID: 2019
		private UnknownFieldSet _unknownFields;

		// Token: 0x040007E4 RID: 2020
		public const int IdFieldNumber = 15;

		// Token: 0x040007E5 RID: 2021
		private uint id_;

		// Token: 0x040007E6 RID: 2022
		public const int IndexFieldNumber = 14;

		// Token: 0x040007E7 RID: 2023
		private uint index_;

		// Token: 0x040007E8 RID: 2024
		public const int LevelFieldNumber = 4;

		// Token: 0x040007E9 RID: 2025
		private uint level_;

		// Token: 0x040007EA RID: 2026
		public const int AvatarTypeFieldNumber = 1;

		// Token: 0x040007EB RID: 2027
		private AvatarType avatarType_;
	}
}
